package gui;

import java.awt.BorderLayout;

import javax.swing.JDialog;
import javax.swing.JFrame;
import javax.swing.JTabbedPane;

import languages.Language;

public class DialogInsertPoint extends JDialog{
	
	private TabInsertPointMiliseconds tiPM;
	private TabInsertPointDegrees tiPD;
	
	private static DialogInsertPoint obj = null;
	
	public DialogInsertPoint(Window parent, Language lang){
		super(parent, lang.dialogInsertPointTitle(), true);

		obj = this;

		this.setDefaultCloseOperation(JDialog.DISPOSE_ON_CLOSE);
		this.getContentPane().setLayout(new BorderLayout());
		
		//tabbed pane
		JTabbedPane tabbedPane = new JTabbedPane();
		
		tiPM = new TabInsertPointMiliseconds(lang, parent);
		tiPD = new TabInsertPointDegrees(lang, parent);
		
		tabbedPane.addTab(lang.tiPMTitle(), tiPM);
		tabbedPane.addTab(lang.tiPDTitle(), tiPD);
		
		this.getContentPane().add(BorderLayout.CENTER, tabbedPane);
		
		this.pack();
		
		this.setVisible(true);
		
	}
}
